<?

if($_SERVER['QUERY_STRING']) $par = decode_params();
if(!$errorMsg && $par[errorMsg]) $errorMsg=$par[errorMsg];
$data = list_reseller_plans($id,'array');
if(is_array($data))
	while(list($k,$v) = each($data)){
        	$buff = explode("|",$v[d]);
                $v[d] = $buff;
                if($v[has_domain]!='false'){
                	$domain_box = '1';
                        $domain_menu = '1';
                }
                if($v[offering]=='true') $hosting .= $v[plan];
                $v[description] = explode("|",$v[description]);
                $template[plans][$k] = $v;
	}

$return_url=$HTTP_GET_VARS[return_url];

$info1 = list_details($id,'array');
$info1 = $info1[0];
$info = array_merge($info1,$info2);
$info[fname]=$info[firstname];
$info[lname]=$info[lastname];
while(list($k,$v)=each($info))	if(!$$k) $$k=$v;


?> 

                  <table align=center width='580' class='border' cellspacing=0>
                    <tbody> 
                    <tr> 
                      <td valign=top align=middle> 
                        <table>
                          <tbody> 
                          <tr> 
                            <td  valign=top align=left> 
                              <?if($errorMsg){ echo "<center><b><font color=red>$errorMsg</font><b></center>"; $errorMsg="";}?>
                            </td>
                          </tr>
                          </tbody>
			</table>
				
      <table width="568">
        <tr> 
          <td colspan=2> 
            <p><font class="text"><?=translate('man_order');?></font></p>
          </td>
        </tr>
      </table>
	                        <?
                                $resellername = get_reseller_name_by_id($id);
                                $_GET[s]=$resellername."_2";
                                $_GET[plan]=$plan_to_display;
                                $_GET[sld] = $sld;
                                $_GET[tld] = $tld;
                                //$_GET[return_url]="https://secure.resellerspanel.com/login/?sid=$sid&action=order";
				eval("\$_GET[return_url]=\"$returnURL_rp\";");
				$_GET[price_type] = 'wholesale';
				$_GET[price_type_validate] = base64_encode(crypt('wholesale'.$price_type_secret));
				// wallet
				$_GET[set_wallet]='y';
				$_GET[lang] = $_SESSION[lang];
				//
				$_GET[from_rp]='y';
                                $order_url = $orderURL; //'http://supremedns.com/order/order.html?';
                                foreach($_GET as $k=>$v){
                                        $order_url.="&$k=".urlencode($v);
                                }
                                include($order_url);
                        ?>	
                      </td>
                    </tr>
                    </tbody>
                  </table>
